package com.hunttown.mes.manage.shiro;

import com.hunttown.mes.rpc.domain.AnalysisManageDTO;

import java.util.Date;

public class ManageAuthorizeBo extends AnalysisManageDTO {

    private static final long serialVersionUID = 1L;

    //Session Id
    private String sessionId;

    //Session Host
    private String host;

    //Session创建时间
    private Date startTime;

    //Session最后交互时间
    private Date lastAccess;

    //Session timeout
    private long timeout;

    //session 是否踢出
    private boolean sessionStatus = Boolean.TRUE;

    public ManageAuthorizeBo() {

    }

    public ManageAuthorizeBo(AnalysisManageDTO user) {
        this.setId(user.getId());
        this.setAdminName(user.getAdminName());
        this.setPwd(user.getPwd());
        this.setNickName(user.getNickName());
        this.setRegTime(user.getRegTime());
        this.setRegIp(user.getRegIp());
        this.setMobile(user.getMobile());
        this.setEmail(user.getEmail());
        this.setLastLoginTime(user.getLastLoginTime());
        this.setLastLoginIp(user.getLastLoginIp());
        this.setLoginTimes(user.getLoginTimes());
        this.setIsSuper(user.getIsSuper());
        this.setSort(user.getSort());
        this.setRemark(user.getRemark());
        this.setCreatePeople(user.getCreatePeople());
        this.setCreateTime(user.getCreateTime());
        this.setUpdateTime(user.getUpdateTime());
        this.setStopFlag(user.getStopFlag());
        this.setDeleteFlag(user.getDeleteFlag());
    }

    public String getSessionId() {
        return sessionId;
    }

    public void setSessionId(String sessionId) {
        this.sessionId = sessionId;
    }

    public String getHost() {
        return host;
    }

    public void setHost(String host) {
        this.host = host;
    }

    public Date getStartTime() {
        return startTime;
    }

    public void setStartTime(Date startTime) {
        this.startTime = startTime;
    }

    public Date getLastAccess() {
        return lastAccess;
    }

    public void setLastAccess(Date lastAccess) {
        this.lastAccess = lastAccess;
    }

    public long getTimeout() {
        return timeout;
    }

    public void setTimeout(long timeout) {
        this.timeout = timeout;
    }

    public boolean isSessionStatus() {
        return sessionStatus;
    }

    public void setSessionStatus(boolean sessionStatus) {
        this.sessionStatus = sessionStatus;
    }
}
